<?
session_start();
include('../../conexion.inc.php');
  $link=Conectarse();
mysql_select_db("gotica_sociosgotica",$link);
echo $_POST['ida'];
$sql3="SELECT * FROM maletin WHERE idarchivo=".$_POST['ida'];
$result=mysql_query($sql3);
$row = mysql_fetch_array($result);
$myFile = $row['file'];
$fh = fopen($myFile, 'w') or die("can't open file");
fclose($fh);
unlink($myFile);
$sql1 = "DELETE FROM maletin  WHERE idarchivo=".$_POST['ida']; 
$resulta1 = mysql_query($sql1);
?>
<SCRIPT LANGUAGE="javascript">
<? echo "location.href = \"maletin.php\" "; ?>
</SCRIPT>